<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>猫眼电影</title>
    <link type="text/css" rel="stylesheet" href="../../static/css/style.css"/>
    <script src="/static/script/jquery-1.7.2.js"></script>
    <script>
      $(function (){
        var s = "全部"
        var showingFilms = "正在热映"
        $("#showing").attr("href","/showFilms?filmState="+showingFilms+"&filmType="+s+"&zone="+s)
        var upcomingFilms = "即将上映"
        $("#upcoming").attr("href","/showFilms?filmState="+upcomingFilms+"&filmType="+s+"&zone="+s)

        $("#film_a").attr("href","/showFilms?filmState="+showingFilms+"&filmType="+s+"&zone="+s)

        var buy = document.getElementsByClassName("buy")
        for(var i=0;i<buy.length;i++) {
          buy[i].onmouseover = function () {
            this.setAttribute("style","background-color: cadetblue");
          }
          buy[i].onmouseout = function () {
            this.setAttribute("style","background-color: #b8dee7;")
          }
        }
      });
    </script>
</head>
<body>
  <!--第一行-->
  <div id="header">
    <table>
      <tr>
        <td>
          <span><img src="/static/img/logo.png" style="float: left;border-radius: 52px"></span>
          <span id="index_logo"><a href="/" style="color:red;margin-top: 10px;float: left;vertical-align: middle;">猫眼电影</a></span>
        </td>

        <td style="background-color: cadetblue"><a href="/main">首页</a></td>
        <td><a id="film_a">电影</a></td>
        <td><a href="/selectFilm">影院</a></td>
        <td><a href="/filmList">榜单</a></td>
        <td>
          <form action="/selectFilm" method="post">
            <input class="search" type="search" placeholder="找影视剧" autocomplete="off" name="filmName"><input class="submit" type="submit" value="搜索">
          </form>
        </td>
        <td><a href="/login">
          {{if .IsLogin}}
          <img src="{{.User.ImgPath}}" style="width: 50px;border-radius: 50px;border: 2px solid darkblue">
          {{else}}
          <img src="/static/img/0.png" style="width: 50px;border-radius: 50px;border: 2px solid darkblue">
          {{end}}
        </a>
        </td>
      </tr>
    </table>
  </div>
  <!--第二行-->
  <div><img src="/static/img/00.png" style="margin-top: 100px;margin-left:80px;width: 1300px;height: 400px"></div>
  <!--第三行-->
  <table class="body">
    <tr>
      <td class="left">
        <table>
          <tr>
            <td colspan="4">
              <span class="title">正在热映（{{.ShowingFilmsNum}}部）</span>
              <span style="color: red;float: right"><a id="showing">全部 ></a></span>
            </td>
          <tr>
          {{range .ShowingFilms1}}
            <td>
              <div><img src={{.ImgPath}} style="width: 160px;height: 250px"></div>
              <span><a href="/filmPage?filmName={{.FilmName}}"><input name="subs" class="buy" type="submit" value="{{.FilmName}}"></a></span>
            </td>
          {{end}}
          </tr>
          <tr>
            {{range .ShowingFilms2}}
            <td>
              <div><img src={{.ImgPath}} style="width: 160px;height: 250px"></div>
              <span><a href="/filmPage?filmName={{.FilmName}}"><input name="subs" class="buy" type="submit" value="{{.FilmName}}"></a></span>
            </td>
            {{end}}
          </tr>
      </table>
      </td>

      <td class="right">
        <table>
          <tr><td><span class="title">票房榜单</span></td></tr>
          {{range .SortFilmByTicketOffice}}
          <tr>
            <td>
            <span><img src="{{.ImgPath}}" style="width: 150px;height: 80px"></span>
            </td>
            <td>
              <span style="font-size: 18px;font-family: '幼圆'">{{.FilmName}}<div style="color: #39987c">￥{{.TicketOffice}}</div></span>
            </td>
          </tr>
          {{end}}
        </table>
      </td>
    </tr>
    <tr>
      <td class="left">
        <table>
          <tr>
            <td colspan="4">
              <span class="title" style="color: #36dee7">即将上映（{{.UpcomingFilmsNum}}部）</span>
              <span><a id="upcoming" style="color: #36dee7;float: right">全部 ></a></span>
            </td>
          <tr>
            {{range .UpcomingFilms1}}
            <td>
              <div><img src={{.ImgPath}} style="width: 160px;height: 250px"></div>
              <span><a href="/filmPage?filmName={{.FilmName}}"><input name="subs" class="buy" type="submit" value="{{.FilmName}}"></a></span>
            </td>
          {{end}}
          </tr>
          <tr>
            {{range .UpcomingFilms2}}
            <td>
              <div><img src={{.ImgPath}} style="width: 160px;height: 250px"></div>
              <span><a href="/filmPage?filmName={{.FilmName}}"><input name="subs" class="buy" type="submit" value="{{.FilmName}}"></a></span>
            </td>
            {{end}}
          </tr>
        </table>
      </td>

      <td class="right">
        <table>
          <tr><td><span class="title">销量榜单</span></td></tr>
          {{range .SortFilmBySales}}
          <tr>
            <td>
              <span><img src="{{.ImgPath}}" style="width: 150px;height: 80px"></span>
            </td>
            <td>
              <span style="font-size: 18px;font-family: '幼圆'">{{.FilmName}}<div style="color: #39987c">{{.Sales}}张</div></span>
            </td>
          </tr>
          {{end}}
        </table>
      </td>
    </tr>
  </table>
  <!--第四行-->
  <div class="bottom">

    商务合作邮箱：v@maoyan.com 客服电话：10105335 违法和不良信息/涉未成年人有害信息举报电话：4006018900<br>

    用户举报/涉未成年人有害信息举报邮箱：tousujubao@meituan.com 舞弊线索举报邮箱：wubijubao@maoyan.com<br>

    中华人民共和国增值电信业务经营许可证 京B2-20190350 | 营业性演出许可证 京演（机构）（2019）4094号<br>

    广播电视节目制作经营许可证 （京）字第08478号 | 网络文化经营许可证 京网文（2022）1334-041号<br>

    艺术品经营单位备案证明 京东艺（2022）0095号<br>

    猫眼用户服务协议 | 猫眼平台交易规则总则 | 隐私政策<br>

    京公网安备 11010102003232号 | 京ICP备16022489号-1<br>

    北京猫眼文化传媒有限公司<br>

    ©2023 猫眼电影 www.maoyan.com<br>
  </div>
</body>
</html>